package com.liming.common.pojo.dto.stock;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.liming.common.pojo.dto.PageDTO;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;

/**
 * @author liming
 * @date 2025/2/23
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "库存流水查询 - query")
public class StockFlowPageQuery extends PageDTO {

    @Schema(description = "商品名称")
    private String productName;

    @Schema(description = "操作类型")
    private Integer type;

    @Schema(description = "操作人|下单人")
    private String operator;

    @Schema(description = "开始日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime startTime;

    @Schema(description = "结束日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime endTime;
}
